package com.mida.app.report.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.mida.bms.requestform.dto.RequestDiagnosisSetDto;
import com.mida.bms.requestform.dto.RequestPageInfoDto;
import com.mida.bms.requestform.dto.ServiceInstanceInfoDto;
import com.mida.bms.requestform.request.PatientRecordVo;
import com.mida.bms.requestform.request.RequestCustomerVO;
import com.mida.bms.requestform.request.RequestFormInfo;
import com.mida.bms.requestform.request.RequestListInfoVO;
import com.mida.bms.requestform.request.reqeustfrom.RegistrationListRequest;
import com.mida.bms.requestform.request.reqeustfrom.RequestServiceInstasnceRequest;
import com.mida.bms.requestform.response.QueryPatientMedicalReportVo;
import com.mida.bms.requestform.response.QueryPatientMedicalVo;
import com.mida.bms.requestform.vo.register.RegisterRequestInfo;
import com.mida.bms.requestform.vo.register.RegisterRequestVo;
import com.mida.bms.requestform.vo.register.RequestExamTechVo;
import com.mida.bms.requestform.vo.register.dto.RequestInfoCondition;
import com.mida.bms.requestform.vo.requestform.ApntRequestLifeCycleVo;
import com.mida.bms.requestform.vo.requestform.RequestCheckService;
import com.mida.bms.requestform.vo.requestform.ServiceInstanceVo;
import com.mida.tool.common.ret.RespBody;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * 申请单域Api
 *
 * @author Peng.Wu
 * @version version-1.0
 * @date 2021/6/22 13:42
 */
public interface RequestFormBmsSvc {

    /**
     * 依据条件查询申请域登记表人员护理
     *
     * @param reqCondition 查询条件
     * @return List<RegisterRequestInfo>
     * @author peng.Wu
     * @date 13:54 2021/6/22
     */
    List<RegisterRequestInfo> findRequestInfoByCondition(RequestInfoCondition reqCondition);

    /**
     * 新增/删除 申请单下检查项目信息
     *
     * @param reqCheckSvc 申请单下检查项目
     * @author peng.Wu
     * @date 13:55 2021/6/22
     */
    void updateCheckServicesByRequestSoId(RequestCheckService reqCheckSvc);

    /**
     * 手工登记 注册申请单信息
     *
     * @param registerRequestVo 注册申请单信息
     * @author peng.Wu
     * @date 13:56 2021/6/22
     */
    void manualRegisterRequest(RegisterRequestVo registerRequestVo);

    /**
     * 新增/更新 检查技术
     *
     * @param examTechVo 检查技术信息
     * @author peng.Wu
     * @date 14:23 2021/6/22
     */
    void updateRequestExamTech(RequestExamTechVo examTechVo);

    /**
     * 获取检查服务实例信息
     *
     * @param requests 项目检查服务实例
     * @return List<ServiceInstanceInfoDto>
     * @author peng.Wu
     * @date 14:55 2021/6/23
     */
    List<ServiceInstanceInfoDto> getReqeustServiceInstanceVos(List<RequestServiceInstasnceRequest> requests);

    RespBody<List<RequestDiagnosisSetDto>> getRequestDiagnosisWithRequestSoids(List<String> requestSoids);

    RespBody<Page<RequestPageInfoDto>> getRequestPageInfoWithCondition(RegistrationListRequest registrationListRequest);

    RespBody<Map<BigDecimal, List<ServiceInstanceInfoDto>>> getBigDecimalListMap(List<BigDecimal> requestSoids);

    Boolean insertRequestLifeCycle(ApntRequestLifeCycleVo apntRequestLifeCycle);

    List<ServiceInstanceVo> findServiceInstancesByRequestSoid(String requestSoid);

    QueryPatientMedicalVo queryPatientMedicalByRequestSoid(BigDecimal requestSoid, BigDecimal msdServiceInstanceSoid);

    QueryPatientMedicalReportVo queryRequestInfoByRequestSoidForResport(BigDecimal requestSoid);

    RespBody<List<RequestServiceInstasnceRequest>> queryServiceByRequestSoidAndSerivceSoid(List<RequestServiceInstasnceRequest> list);

    Boolean updatePatientRecord(PatientRecordVo patientRecord);

    BigDecimal findRequestServiceSoid(BigDecimal requestSoid, BigDecimal msdServiceInstanceSoid);

    RespBody<Page<RequestListInfoVO>> getRequestListInfo(RequestFormInfo request);

    RespBody<RequestCustomerVO> getRequsetByRequisitionId(BigDecimal requisitionId);
}
